<?php
namespace  app\common\validate;

use think\Validate;
class Admin extends Validate {
    protected $rule = [
        'username'  =>  'require|max:25',
        'userpwd' =>  'require|max:25',
    ];
    
    protected $message = [
        'username.email'  =>  '用户名必须',
        'userpwd.require' =>  '用户密码必须',
    ];
    
    protected $scene = [
        'add'   =>  ['username','userpwd']
       
    ];
}